﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;

namespace FrameEngine
{
    public interface IApplication
    {
        /// <summary>
        /// 主程序标题
        /// </summary>
        string Caption { get; set; }
        /// <summary>
        /// 主程序窗体
        /// </summary>
        Window MainWindow { get; set; }

        /// <summary>
        /// 主操作控件
        /// </summary>
        FrameworkElement GlobeControl { get; }


        /// <summary>
        /// 当前的工具
        /// </summary>
        ITool CurrentTool { get; set; }


        /// <summary>
        /// 系统的默认工具
        /// </summary>
        ITool PanTool { get; set; }


        /// <summary>
        /// 当前是否可以切换工具
        /// </summary>
        bool IsCanChangeTool { get; set; }


        /// <summary>
        /// 状态栏
        /// </summary>
        IStateBar StateBar { get; set; }

        /// <summary>
        /// 用户信息栏
        /// </summary>
        IStateBar UserInfoBar { get; set; }

        /// <summary>
        /// 根据关键字，得到所有的命令名称
        /// </summary>
        /// <param name="pKey"></param>
        /// <returns></returns>
        List<ICommand> GetCommandsByKey(string pKey);


        /// <summary>
        /// 注册命令
        /// </summary>
        /// <param name="pCommand"></param>
        void RegisterCommand(ICommand pCommand);
    }
}
